//
//  HWTieZiTableViewCell.m
//  HWanGame
//
//  Created by 陈道斌 on 2019/10/22.
//  Copyright © 2019 Chendaobin. All rights reserved.
//

#import "HWTieZiTableViewCell.h"

@implementation HWTieZiTableViewCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}


-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    
    if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
        
        [self setupUI];
        
    }
    
    return  self;
    
    
}


- (void)setupUI {
    
    self.headPortraitImageView = [[UIImageView alloc]initWithFrame:CGRectMake(9, 9, 40, 40)];
    self.headPortraitImageView.image = [UIImage imageNamed:@"morenTuPenson_ico"];
    self.headPortraitImageView.layer.cornerRadius = 40/2;
    self.headPortraitImageView.layer.masksToBounds = YES;
    [self.contentView addSubview: self.headPortraitImageView];
    
     CGSize size =  [WMUtil  strName:@"18330491321_s" fontSize:[UIFont systemFontOfSize:14] boundingRectWithSize:CGSizeMake(1000, 1000)];
    
    
     self.zhanghaoLabel = [[UILabel alloc]initWithFrame:CGRectMake(self.headPortraitImageView.right+10, 14, size.width, 13)];
     self.zhanghaoLabel.text = @"18330491321_s";
     self.zhanghaoLabel.textColor = RGB(51, 51, 51);
     self.zhanghaoLabel.font = [UIFont systemFontOfSize:12];
   //  self.zhanghaoLabel.backgroundColor = [UIColor redColor];
     
     [self.contentView addSubview:self.zhanghaoLabel];
    
    
     self.xiaohaoLabel = [[UILabel alloc]initWithFrame:CGRectMake(self.headPortraitImageView.right+10, self.zhanghaoLabel.bottom+6, 200, 12)];
     self.xiaohaoLabel.text = @"昨天 09:34";
     self.xiaohaoLabel.textColor = RGB(102 , 102 ,102);
     self.xiaohaoLabel.font = [UIFont systemFontOfSize:11];
     [self.contentView addSubview:self.xiaohaoLabel];
    
      self.contentIsNotLabel = [[UILabel alloc]initWithFrame:CGRectMake(12, self.headPortraitImageView.bottom+9, kScreenW-24, 30)];
      self.contentIsNotLabel.text = @"dcdhuuojubbou你是我的回复就跑了都会促使度和你是我的回复就跑了都会促使度发布 你是我的回复就跑了都会促使度vu 你是我的回复就跑了都会促使度符合发布会和vujc";
      self.contentIsNotLabel.textColor = RGB(51 , 51 ,51);
      self.contentIsNotLabel.font = [UIFont systemFontOfSize:12];
      self.contentIsNotLabel.numberOfLines = 0;
  //  self.contentIsNotLabel.backgroundColor = [UIColor redColor];
      [self.contentView addSubview:self.contentIsNotLabel];
    
    
    
      self.quxiaoBut = [UIButton buttonWithType:UIButtonTypeCustom];
      self.quxiaoBut.frame = CGRectMake(kScreenW-73-12, 16, 73, 25);
      self.quxiaoBut.backgroundColor = blueBackgroundBT;
      self.quxiaoBut.layer.cornerRadius = 25/2;
      self.quxiaoBut.layer.masksToBounds = YES;
      self.quxiaoBut.titleLabel.font = [UIFont systemFontOfSize:13];
      [self.quxiaoBut setTitleColor:[UIColor whiteColor] forState:UIControlStateNormal];
      
      [self.quxiaoBut setTitle:@"取消关注" forState:UIControlStateNormal];
      [self.contentView addSubview: self.quxiaoBut];
      
    

    
    
    
     self.fengexianView = [[UIView alloc]initWithFrame:CGRectMake(0, 101, kScreenW, 1)];
     self.fengexianView.backgroundColor = RGB(232, 232, 242);
     [self.contentView addSubview:self.fengexianView];
    
}

@end
